import testDialogDom from './index.vue'

const testDialog = {};

testDialog.install = function (Vue, option) {
  const TestDialogInstance = Vue.extend(testDialogDom);
  let msg;
  const initInstance = () => {
    msg = new TestDialogInstance();
    // let nameSpan = name.$mount().$el;
    // document.body.appendChild(nameSpan);
  }
  Vue.prototype.$testDialog = {
    showMessage(option){
      initInstance();
      // if(typeof option === 'string'){
      //   name.firstName = option;
      // }else if(typeof option === 'object'){
      //   Object.assign(name, option);
      // }
      msg = option
      return initInstance;
    }
  };
}

export default testDialog;